

addEvent(window,"load",function(){
	//首页搜索栏//
	var input_search=document.getElementById("input_search");
	var form_search=document.getElementById("search");
	var input_down=document.getElementById("input_down");
	var select_travel=document.getElementById("select_travel");
	var hot_close=document.getElementById("hot_close");
    addEvent(input_search,"click",function(){
    	input_down.style.display="block";
    });
    /*addEvent(form_search,"mouseleave",function(){
    	input_down.style.display="none";
    });*/
    addEvent(select_travel,"mouseover",function(){
    	input_down.style.display="none";
    });
    addEvent(hot_close,"click",function(){
    	input_down.style.display="none";
    });
    $("#select_name").each(function(){
        var that=$(this);
        that.hoverDelay({
            hoverEvent:function(){
            $("#select_down").css("display","block");
        },
            outEvent:function(){
           $("#select_down").css("display","none")
         }
        });
    });
    $("#select_down div").on("click",function(){
    	var value=$(this).text();
    	$("#search_goods").text(value);
    	$("#select_down div").css("display","block");
    	$(this).css("display","none");
    	$("#select_down").css("display","none");
    });

    //选择城市//
    $("#letter_word").children("div").on("click",function(){
    	$(".city-choose").hide();
    	$("#letter_word").children("div").removeClass("city-click");
    	$(this).addClass("city-click");
    	var id=$(this).attr("classify");
    	var city=document.getElementById(id);
    	city.style.display="block";
    });

    $(".city a").on("click",function(){
    	var value=$(this).text();
    	$("#zhan").text(value);
    });


    //首页导航栏
    $(".nav-li a.nli-a").on("click",function(evt){
    	var e=evt||window.event;
    	pre(e);
    	$(".nav-li>a").css({"font-weight":"normal","background-color":"#37C249"});
    	$(this).css("font-weight","bold");
    	$(this).css("background-color","#398439");
    });

    
    
});